package org.lts.yuqueexportor;

import lombok.extern.slf4j.Slf4j;
import org.lts.yuqueexportor.service.ExportService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.CommandLineRunner;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

/**
 * 语雀文档导出工具启动类
 */
@Slf4j
@SpringBootApplication
public class YuqueexportorApplication implements CommandLineRunner {

    @Autowired
    private ExportService exportService;

    public static void main(String[] args) {
        SpringApplication.run(YuqueexportorApplication.class, args);
    }

    @Override
    public void run(String... args) throws Exception {
        log.info("语雀文档导出工具启动");
        exportService.executeExport();
        log.info("程序执行完毕");
    }
}
